package com.dxt.dao;

import com.dxt.model.InterfaceLogBean;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Options;
import org.apache.ibatis.annotations.Update;
import org.springframework.stereotype.Repository;

@Repository
public interface InterfaceLogDao {

    @Insert("insert into dxt_interface_log (req_encrypted_str,req_str,create_date) " +
            "value (#{reqEncryptedStr},#{reqStr},#{createDate})")
    @Options(useGeneratedKeys = true, keyProperty = "id", keyColumn = "id")
    int addInterfaceLog(InterfaceLogBean interfaceLogBean);

    @Update("update dxt_interface_log set deal_type = #{dealType},deal_date = #{dealDate},res_str = #{resStr} where " +
            " id = #{id}")
    int modifyInterfaceLog(InterfaceLogBean interfaceLogBean);
}
